using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.U2D;

namespace Elvex
{
    public static class Atlas
    {
        public static Sprite Load(string asset, string name)
        {
            var atlas = Assets.Load<SpriteAtlas>(asset);
            if (null == atlas)
            {
                Debug.LogErrorFormat("{0} Load Fail.", asset);
                return null;
            }
            return atlas.GetSprite(asset);
        }
    }
}


